import {
	request
} from '@/util/api.js'

// 获取产品分类
export const productCategory = (data) => {
	return request({
		url: 'api/wap_product/get_form_sign',
		method: 'GET',
		data
	})
}
export const productListData = (data) => {
	return request({
		url: 'api/wap_product/product_list_data',
		method: 'POST',
		data
	})
}

// 获取产品列表
export const getProductList = (data) => {
	return request({
		url: 'api/wap_product/get_product_list',
		method: 'POST',
		data
	})
}

// 获取产品详情--参数型
export const getProductDetail = (data) => {
	return request({
		url: 'api/wap_product/get_product_detail',
		method: 'POST',
		data
	})
}

// 获取产品详情--图文型
export const getImgtextProductDetail = (data) => {
	return request({
		url: 'api/wap_product/productEdit',
		method: 'POST',
		data
	})
}


// 产品型号切换
export const specifications = (data) => {
	return request({
		url: 'api/wap_product/specifications',
		method: 'POST',
		data
	})
}

// 产品询价
export const getAdvisory = (data) => {
	return request({
		url: 'api/wap_product/get_advisory',
		method: 'POST',
		data
	})
}

// 产品询价提交
export const postAdvisory = (data) => {
	return request({
		url: 'api/wap_product/post_advisory',
		method: 'POST',
		data
	})
}

// 产品对比
export const getProductCompared = (ids) => {
	return request({
		url: 'api/wap_product/get_product_compared',
		method: 'POST',
		data: {
			ids
		}
	})
}

// 添加产品

// 获取品牌
export const getProductBrands = (data) => {
	return request({
		url: 'api/product/get_product_brands',
		method: 'POST',
		data
	})
}

// 获取系列
export const getProductSeries = (data) => {
	return request({
		url: 'api/product/get_product_series',
		method: 'POST',
		data
	})
}

// 获取产品
export const getProductProducts = (data) => {
	return request({
		url: 'api/product/get_product_products',
		method: 'POST',
		data
	})
}

// 选择产品
export const getApiProducts = (data) => {
	return request({
		url: 'api/product/get_api_products',
		method: 'POST',
		data
	})
}

// 添加产品
export const addApiProduct = (data) => {
	return request({
		url: 'api/product/add_api_product',
		method: 'POST',
		data
	})
}


// 产品文件列表
export const filesProduct = (data) => {
	return request({
		url: 'api/files/product',
		method: 'get',
		data
	})
}